<#assign group_orl = param.value('group_orl')?if_exists>
<#assign category_orl = param.value('category_orl')?if_exists>

<form id="form" method="post"></form>

<div id="sub_column_content">

  <#include "admin.sub.html">
  <div class="document-head-menu tr">
    <span class="button medium icon"><a href="dispIssueList.me${param.get('?group_orl=')?html}"><span class="iconset accept"></span>목록</a></span>
    <span class="button medium icon"><a href="dispIssueInsert.me${param.get('?')?html}"><span class="iconset accept"></span>등록</a></span>
  </div>


  <#assign i = 0>
  <#list O.listGroup as obj>
<div class="document-list">
  <table cellspacing="0" border="1" summary="" class="tbl_type">
  <caption>Total ${paging.total_count?string(",###")} Page ${paging.page?string(",###")}/${paging.total_page?string(",###")}</caption>
  <colgroup>
  <col width="120"><col><col width="120"><col>
  </colgroup>
   <tbody>

  <tr>
  <tr>
  <th scope="row">기능</th>
  <td colspan="3">
  <span class="button medium icon"><a href="javascript:del(${obj.issue_orl});"><span class="iconset delete"></span>삭제</a></span>
  </td>
  </tr>

  <tr>
  <th scope="row">분류</th>
  <td>${obj.category_orl?if_exists}</td>
  <th scope="row">상태</th>
  <td>${obj.stat_code_orl?if_exists}</td>
  </tr>

  <tr>
  <th scope="row">작성자</th>
  <td>${obj.user_name?if_exists}</td>
  <th scope="row">작성일</th> 
  <td><#if obj.reg_date?if_exists != ""><#assign reg_date = obj.reg_date?datetime("yyyyMMddHHmmss")>${reg_date?string("yyyy/MM/dd HH:mm:ss")}</#if></td>
  </tr>

  <tr>
  <th scope="row">제목</th>
  <td colspan="3">${obj.title?if_exists}</td>
  </tr>

  <tr>
  <th scope="row">내용</th>
  <td colspan="3">${obj.content}</td>
  </tr>

  <tr>
    <td colspan="4">

    <div>
      <#list daoFile.getFileDownload('${MM.module_orl}','1','${obj.issue_orl}') as objFile>
      <a href="${objFile.url}${param.get('?file_orl=${objFile.file_orl}')?html}">${objFile.filename}</a> (${objFile.size_unit}) <#if objFile_has_next>,</#if>
      </#list>
      <p>IP : ${obj.ipaddress}</p>
    </div>

    </td>
  </tr>

  </tbody> 
  </table>
</div>

  <#assign i = i + 1>
  </#list>

  <@pagenavigator url = param.get('?page=')?j_string form="#form" params = paging />

</div>

<script>
  // 삭제
  function del(issue_orl) {
    jQuery('#form').jaAction({ 
      formAttr : 'action=./procIssueDelete.me&method=post', 
      param : _mei_gb_params + '&issue_orl=' + issue_orl + '&group_orl=${group_orl}', 
      ask : 'del' ,
      <#if i == 1>
        redirect : './dispIssueList.me?' + _mei_gb_params 
      <#else>
      afterSend : function() { location.reload(); }
      </#if>
    });
  }

</script>
